<script setup lang="ts">
import {defineComponent, h, reactive} from "vue"
// import sortable from "sortablejs"
// import { Tree } from "../../../../ui-base"
//
const list = reactive([])

// 定义组件
const Item = defineComponent({name:"item",props:{item:{type:Object}},setup:(props) => () => h('div',[props.item?.name,props.item?.children.map((d:any) => h(Item,{item:d}))])})
</script>

<template>
    <div>
        <template v-for="item in list">
            <Item :item="item"></Item>
        </template>
    </div>
</template>